{% load forum_tags %}


<div class="ui form-wrap segment" style="background-color: #f9f6f4">
    <b>Moderating {{ post.get_type_display }}: {{ post.title }}</b>

    <form method="post" class="ui form" id="modform" action="{% url 'post_moderate' post.uid %}">

        {% csrf_token %}

        <div class="ui segment">

            <div class="field">

                <button class="ui green mini button" name="action" value="open">
                    Open
                </button>

                <button class="ui red mini button" name="action" value="delete">
                    Delete
                </button>

                {% if post.is_spam %}
                    <button class="ui mini green button" name="action" value="spam">
                        Not spam
                    </button>
                {% else %}
                    <button class="ui red mini  button" name="action" value="spam">
                        Spam
                    </button>
                {% endif %}

            </div>

            <div class="field">
                <button class="ui grey mini button" name="action" value="bump">
                    Bump
                </button>

                <button class="ui grey mini button" name="action" value="offtopic">
                    Off topic
                </button>

                {% if ALLOW_POST_CLOSING %}
                    <button class="ui grey mini button" name="action" value="close">
                        Close
                    </button>
                {% endif %}


                {% if not post.is_toplevel %}
                    <button class="ui grey mini button" name="action" value="relocate">
                        Relocate
                    </button>
                {% endif %}

            </div>

            <div class="field">

                <button class="ui mini button" onclick="javascript:obj=$('#modpanel').remove();">
                    <i class="close icon"></i> Exit moderation
                </button>

            </div>
        </div>
        <p>
            If a post is a duplicate please indicate that as an answer.
        </p>
        <p>
            If this is a cross-post with bioinformatics relevance please provide the link as an answer.
        </p>

        <p>See <a href="/info/mods" target="_blank">moderator resources</a> for more information on what each action
            does</p>
    </form>
</div>



